package com.fsc.mapper;

import com.fsc.entity.domain.ParentInfo;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.fsc.entity.domain.StudentInfo;
import com.fsc.entity.dto.ParentDTO;
import com.fsc.entity.dto.StudentDTO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

/**
* @author 86183
* @description 针对表【parent_info(家长信息表)】的数据库操作Mapper
* @createDate 2024-06-02 13:15:22
* @Entity com.fsc.domain.ParentInfo
*/
@Mapper
public interface ParentInfoMapper extends BaseMapper<ParentInfo> {
    @Select("SELECT * FROM parent_info WHERE parent_id= #{parentId}")
    ParentInfo getParentById(int parentId);

    @Update("UPDATE parent_info " +
            "SET " +
            "gender = #{gender}, " +
            "parent_name = #{parentName} " +
            "WHERE parent_id= #{parentId}")
    void update(ParentDTO parentDTO);
}




